                <div class="modal fade" id="skuModal" data-keyboard="false" data-backdrop="static" tabindex="-1">
                  <div class="modal-dialog" role="document">
                    <div class="modal-content">
			            <div class="modal-header">
			                <h3 class="modal-title pull-left" id="sku-add-modal-title">增加库存</h3>
			            </div>
                      <div class="modal-body">
                        <form id="addSkuForm">
                         <div id="specSelect">
                         </div>
                          <div class="form-group">
                            <label for="message-text" class="control-label">图片：</label>
                      <ul class="list-inline clearfix lyear-uploads-pic" id="skuLi">
<!--                     <li class="col-xs-4 col-sm-3 col-md-3 imgObj">
                          <figure>
                            <input type="hidden" value="/images/gallery/15.jpg" name="productImgs"/>
                            <img   data-th-src="@{/images/gallery/15.jpg}" >
                            <figcaption>
                              <a class="btn btn-round btn-square btn-primary" href="#!"><i class="mdi mdi-eye"></i></a>
                              <a class="btn btn-round btn-square btn-danger" href="#!"><i class="mdi mdi-delete"></i></a>
                            </figcaption>
                          </figure>
                        </li> -->
                        <li class="col-xs-4 col-sm-3 col-md-3 upElement" id="skuUpElement">
                          <a class="pic-add" id="add-pic-btn" href="#!" title="点击上传"></a>
                          <input class="upload upFile" id="skuFile" type="file" name="productFile">
                          <input type="hidden" name="skuImgUrl" id="skuImgUrl"/>
                        </li>
                      </ul>
                          </div>                         
                          <div class="form-group">
                            <label for="message-text" class="control-label">库存：</label>
                            <input type="number" class="form-control" id="sku-stock">
                          </div>
                          <div class="form-group">
                            <label for="message-text" class="control-label">价格：</label>
                            <input type="number" class="form-control" id="sku-price">
                          </div>
                          <div class="form-group">
                            <label for="message-text" class="control-label">原始价格：</label>
                            <input type="number" class="form-control" id="sku-oriprice">
                          </div>                                                    
                        </form>
                      </div>
                      <div class="modal-footer">
                        <button type="button" class="btn btn-primary" id="saveSku">保存</button>
                        <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
                        <button class="btn-hide d-none" type="button"></button>
                      </div>
                    </div>
                  </div>
                </div>
<script data-th-inline="javascript">
$("#saveSku").click(function(){
	var arrs=[];
	$("#specSelect").find("select").each(function(index,ele){
		var specName = $(ele).parent().siblings(".control-label").text();
		var specVal=$(ele).val();
		arrs.push(specName+specVal);
	})
	var skuStock=$("#sku-stock").val();
	var skuPrice=$("#sku-price").val();
	var skuOriprice=$("#sku-oriprice").val();
	var skuImg=$("#skuImgUrl").val();
	var skuTr='<tr class="sku"><td class="sku_spec">'+arrs.join(",")+'</td><td class="sku_price">'+skuPrice+'</td><td class="sku_oripice">'+skuOriprice+'</td><td class="sku_img"><input type="hidden" class="skuImgUrl" value="'+skuImg+'"/><img src="'+skuImg+'" class="skuImg"/></td><td class="sku_stock">'+skuStock+'</td><td><a href="#!" class="btn btn-xs btn-danger delBtn">删除</a></td></tr>';
    $("#skuBody").append(skuTr);
    $MB.closeAndRestModal("skuModal");
});
</script>